import java.util.Scanner;
public class person2 {
    public static void main(String args[]) {
        int total=0;
        int count=0;
        System.out.println("输入查找区间，使用回车隔开：");
        Scanner read1 =new Scanner(System.in);
        Scanner read2 =new Scanner(System.in);
        int a=read1.nextInt();
        int b=read2.nextInt();
        System.out.println(a+"到"+b+"范围以内的完全数有：");
        for (int i=a;i<=b ;i++) {
            for(int j=1;j<i;j++){
                if(i%j==0) {
                    total = total + j;
                }
            }
            if(total==i){
                System.out.println(i);
                count++;
            }
            total=0;
        }
        if (count==0){
            System.out.println("0个，该区间内没有完全数");
        }
    }
}

